1. Field of the Invention
The present invention relates to an audio codec with an audio jack detection function and an audio jack detection method, especially to an audio codec and an audio jack detection method executing detection through an existing/common pin instead of an additional/dedicated pin.
2. Description of Related Art
Generally speaking, an electronic device with an audio function is equipped with an earphone jack and/or a microphone jack for users to insert an earphone and/or a microphone into the electronic device. Some electronic device is only equipped with one of the earphone and microphone jacks; some is equipped with both of them; and some is equipped with a composite jack for a headset including the functions of earphone and microphone to connect. No matter what kind of the electronic device is, it needs to detect whether an earphone, a microphone or a multi-function headset is inserted or detached, so as to react in response to the detection result. The existing jack detection technique sets an independent detecting mechanism on a circuit board where an audio codec (coder/decoder) is set as well, then detects whether a plug is inserted or removed by the detecting mechanism, afterwards transmits the detection result to the audio codec through the pin thereof dedicated to the detection, and finally has the audio codec determine the presence or absence of the plug in accordance with the detection result. However, this manner has to set a detecting mechanism outside the audio codec and consequently consume a pin of the audio codec; therefore it is unfavorable to the cost and size of an audio codec solution.
In light of the above, the current audio jack detection technique is obviously not good enough, which means that this technique field needs a cost-effective solution to realize the audio jack detection.
People who are interested in the prior arts may refer to the Taiwan (R.O.C.) patents by the following patent numbers: I236191; I358862; M383236.